package practise1;

public class Duck {
   private String name;
   private int legnum;

   public Duck(String name,int legnum){
       this.name=name;
       this.legnum=legnum;
   }
    public String getName() {
        return name;
    }

    public int getLegnum() {
        return legnum;
    }

    public void shout(){
        System.out.println("嘎嘎嘎......");
    }
}
